<div class="frame_configDiv">
	<form name="configForm" id="configForm" action="administrator-system-donav" method="post">
	  <table width="100%" border="1" cellpadding="0" cellspacing="0" bordercolor="#c8d9e9">
		<tr>
		  <td>首页导航</td>
		</tr>
		<tr>
			<td>
				<div><input type="button" value="添加" onclick="addNav(this);" /></div>
				<?foreach($this->navArray as $value):?>
					<div class="navDiv">导航名：<input name="navName[]" type="text" value="<?=$value['name']?>" />&nbsp;&nbsp;&nbsp;&nbsp;导航地址：<input name="navUrl[]" type="text" value="<?=$value['url']?>" />&nbsp;&nbsp;&nbsp;&nbsp;顺序：<input name="navOrder[]" type="text" value="<?=$value['order']?>" />&nbsp;&nbsp;&nbsp;&nbsp;<input type="button" value="删除" onclick="subNav(this);" /></div>
				<?endforeach;?>
			</td>
		</tr>
		<tr>
		  <td><input type="submit" value="提交" /></td>
		</tr>
	  </table>
	</form>
</div>
<script>
function addNav(thisButton){
	$(thisButton).parent().parent().append('<div class="navDiv">导航名：<input name="navName[]" type="text" value="" />&nbsp;&nbsp;&nbsp;&nbsp;导航地址：<input name="navUrl[]" type="text" value="" />&nbsp;&nbsp;&nbsp;&nbsp;顺序：<input name="navOrder[]" type="text" value="" />&nbsp;&nbsp;&nbsp;&nbsp;<input type="button" value="删除" onclick="subNav(this);" /></div>');
	commonEffection.resetFrame('admins_frame',true);
}
function subNav(thisButton){
	if($('.navDiv').size()>1){
		$(thisButton).parent().remove();
		commonEffection.resetFrame('admins_frame',true);
	}
}
</script>